<?php
	include("library/vars.php");
	include("library/config.php");
	include("library/opendb.php");
	
	$query="DELETE FROM seasons WHERE show_ID='$show' AND season='$season'";
	mysql_query($query) or die('Error, query1 failed');
	
	$query2="DELETE FROM episodes WHERE season_ID='$season' AND show_ID='$show'";
	mysql_query($query2) or die('Error, query2 failed');
	
	include 'library/closedb.php';
	header( 'Location: index.php?s=' . $show . '&m=season_deleted' );
?>